package com.muyu.cloud.commodity.mapper;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import com.muyu.cloud.commodity.domain.req.ProductCommentListReq;
import com.muyu.cloud.commodity.domain.resp.ProductCommentListResp;
import java.util.List;

import java.math.BigDecimal;

/**
 * @
 * @descriptions: ProductCommentMapper
 * @author: LiuSuo
 * @date: 10:05
 * @version: 1.0
 */
@Mapper
public interface ProductCommentMapper {
    BigDecimal selectAvgScoreByProductId(@Param("id") Long id);

    Integer countByProductId(@Param("id") Long id);

    List<ProductCommentListResp> selectPageByQuery(ProductCommentListReq req);

    int updateStatusByIds(@Param("ids") List<Long> ids, @Param("status") Integer status);
}
